package org.devocean.groupbuying.dao.impl;

import java.util.List;

import javax.persistence.EntityManager;
import javax.persistence.PersistenceContext;

import org.devocean.groupbuying.dao.ModuleDAO;
import org.devocean.groupbuying.domain.Module;
import org.springframework.stereotype.Repository;

@Repository
public class ModuleDAOImpl implements ModuleDAO {

	@PersistenceContext
	private EntityManager em;

	public List<Module> getModule() {
		return em.createQuery("select m from Module m", Module.class)
				.getResultList();
	}

}
